<?php
/* [$WindsForce] (C)Hunzhiwange.COM Since 2014.07.23.
   家居公司商家后台提醒模型($$)*/

!defined('Q_PATH') && exit;

class JiajucompanynoticeModel extends CommonModel{

	static public function init__(){
		return array(
			'table_name'=>'jiajucompanynotice',
			'autofill'=>array(
				array('user_id','userId','create','callback'),
				array('jiajucompanynotice_username','userName','create','callback'),
				array('jiajucompanynotice_edituserid','userId','all','callback'),
				array('jiajucompanynotice_editusername','userName','all','callback'),
			),
			'check'=>array(
				'jiajucompanynotice_content'=>array(
					array('require',Q::L('通知内容不能为空','__APPJIAJU_COMMON_LANG__@Model')),
					array('max_length',256,Q::L('通知内容不能超过256个字符','__APPJIAJU_COMMON_LANG__@Model')),
				),
			),
		);
	}

	static function F(){
		$arrArgs=func_get_args();
		return ModelMeta::instance(__CLASS__)->findByArgs($arrArgs);
	}

	static function M(){
		return ModelMeta::instance(__CLASS__);
	}

	protected function beforeSave_(){
		$this->jiajucompanynotice_content=C::cleanJs($this->jiajucompanynotice_content);
	}

}
